﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DAL;
using Model;
using System.Data;
using System.Data.SqlClient;


namespace BLL
{
    public class StudentInfoEntityBLL
    {
        private readonly StudentInfoEntityDal studentinfodal = null;
        public StudentInfoEntityBLL()
        {
            studentinfodal = new StudentInfoEntityDal();
        }

        #region 选择学生信息通过学号---周洲--2015-11-21


        /// <summary>
        /// 选择学生信息通过学号---周洲--2015-11-21
        /// </summary>
        /// <param name="studentinfo"></param>
        /// <returns></returns>
        public DataTable SelectStudentInfoByID(StudentInfoEntity studentinfo)
        {
            return studentinfodal.SelectStudentInfoByID(studentinfo);
        }
        #endregion

        #region 通过studentID选择学生的试卷类型（A,B,C）--周洲--2015年11月21日
        /// <summary>
        /// 通过studentID选择学生的试卷类型（A,B,C）--周洲--2015年11月21日
        /// </summary>
        /// <param name="studentinfo"></param>
        /// <returns></returns>
        public DataTable SelectPaperTypebyStudentID(StudentBindPaperTypeEntity studentinfo)
        {
            return studentinfodal.SelectPaperTypebyStudentID(studentinfo);
        }
        #endregion
        #region" 查出学生的学号和姓名-韩梦甜-2015-12-16"
        /// <summary>
        ///  查出学生的学号和姓名-韩梦甜-2015-12-16
        /// </summary>
        /// <param name="studentid"></param>
        /// <returns></returns>
        public DataTable SelectStudentNameByStudentID(string studentid)
        {
            DataTable dt;
            dt = studentinfodal.SelectStudentNameByStudentID(studentid);
            return dt;
        }
        #endregion
        #region"模糊查询学生的学号和姓名-韩梦甜-2015-12-16"
        /// <summary>
        /// 模糊查询学生的学号和姓名-韩梦甜-2015-12-16
        /// </summary>
        /// <param name="studentinfo"></param>
        /// <returns></returns>
        public DataTable SelectVagueStudent(StudentInfoEntity studentinfo)
        {
            DataTable dt;
            dt = studentinfodal.SelectVagueStudent(studentinfo);
            return dt;

        }
        #endregion
        #region"根据学号查询学生所在学院ID-韩梦甜-2015-12-16"
        /// <summary>
        /// 根据学号查询学生所在学院ID-韩梦甜-2015-12-16
        /// </summary>
        /// <param name="studentinfo"></param>
        /// <returns></returns>
        public DataTable SelectCollegeIDByStudentID(StudentInfoEntity studentinfo)
        {
            DataTable dt;
            dt = studentinfodal.SelectCollegeIDByStudentID(studentinfo);
            return dt;

        }
        /// <summary>
        /// 选择学生信息通过验证码---苑仁杰--2018-12-20
        /// </summary>
        /// <param name="studentinfo"></param>
        /// <returns></returns>
        public DataTable SelectStudentInfoBycode(StudentInfoEntity studentinfo)
        {
            return studentinfodal.SelectStudentInfoBycode(studentinfo);
        }
        #endregion
        #region 清空验证码通过学号---苑仁杰--2018-12-20
        public int UpdateStudentInfoByID(StudentInfoEntity studentinfo)
        {
            return studentinfodal.UpdateStudentInfoBycode(studentinfo);
        }
        #endregion

    }
}
